import request from '@/utils/request.js'


//一一对应 接口的函数封装
export const login = (data) => {
  return request({
    method: "post",
    url: "/users/checkLogin",
    data: data
  })
}

//添加账号
export const usersAdd = (data) => {
  return request({
    method: "post",
    url: "/users/add",
    data: data
  })
}

//请求用户列表
export const usersList = (params) => {
  return request({
    method: "get",
    url: "/users/list",
    params: params
  })
}


//获取用户基本信息
export const userInfo = (params) => {
  return request({
    method: "get",
    url: "/users/accountinfo",
    params: params
  })
}

//批量删
export const delAllUser = (params) => {
  return request({
    method: "get",
    url: "/users/batchdel",
    params
  })
}
//单删

export const delUser = (params) => {
  return request({
    method: "get",
    url: "/users/del",
    params
  })
  
}

//修改账号信息
export const usersEdit = (data) => {
  return request({
    method: "post",
    url: "/users/edit",
    data
  })
}


